package com.carkeeper.service.serviceFallback;

import com.carkeeper.dto.ComponentBrandDTO;
import com.carkeeper.service.ComponentBrandFeign;
import feign.hystrix.FallbackFactory;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class ComponentBrandFallbackFactory implements FallbackFactory<ComponentBrandFeign>{
    @Override
    public ComponentBrandFeign create(Throwable throwable) {
        return new ComponentBrandFeign(){
            @Override
            public ComponentBrandDTO getComponentBrand(Long id) {
                return null;
            }

            @Override
            public List<ComponentBrandDTO> getByIds(List<Long> ids) {
                return null;
            }
        };
    }
}
